package com.lhc.service;

import com.lhc.pojo.ResultVO;
import com.lhc.pojo.User;

import javax.jws.soap.SOAPBinding;
import java.sql.SQLException;

/**
 * @author lhc
 * @version V1.0
 * @date 2021/06/30
 **/
public interface UserService {
    /**
     * 添加用户
     * @param user
     * @return
     * @throws SQLException
     */
    int insert(User user) throws SQLException;

    /**
     * 登录业务
     * @param username
     * @param password
     * @return
     * @throws SQLException
     */
    ResultVO login(String username, String password) throws SQLException;

    /**
     * 根据用户名查找用户
     * @param username
     * @return
     * @throws SQLException
     */
    User findByName(String username) throws SQLException;
}
